import cookie from "react-cookies";
import { getSecretString } from "./encrypt";
export default function getImgInfo(data: string) {
  const params = {
    time: new Date().getTime(),
    token: cookie.load("collegeToken"),
    storeName: data
  };

  //   console.log(getSecretString(JSON.stringify(params)));
  const myData = getSecretString(JSON.stringify(params));

  return myData
    .replace(/\%/g, "%25")
    .replace(/\+/g, "%2B")
    .replace(/\"/g, "%22")
    .replace(/\'/g, "%27")
    .replace(/\//g, "%2F");
}
